/*******************************************************************/
/* @ All Rights Reserved Copyright (C) 2014 broada,Co.,Ltd.        */
/*                                                                 */
/*  NAME      = frcmd_parse.h                                      */
/*  NOTE      = ����ͻ���                                          */
/*  DATE      = 2014/12/05                                         */
/*******************************************************************/

#ifndef __FRCMD_PARSE_H_
#define __FRCMD_PARSE_H_

#define CMD_ACTION_COMMIT    1
#define CMD_ACTION_ROLLBACK  2

#define OBJECT_L7               1
#define OBJECT_L7_DEFAULT       2
#define OBJECT_FILTER           3
#define OBJECT_JAVA             4

char* contact_ipport(char *ip, char *port);
int l7_add(char *ip_proto, char *ip_addr, char *port, char *l7_proto);
int l7_del(char *ip_proto, char *ip_addr, char *port);
int l7_default_add(char *ip_proto, char *l7_proto);
int l7_default_del(char *ip_proto);
int l7_default_clear(void);
int l7_clear();
int filter_add(char *macaddr, char* ip_proto, char *src_iprange_portrange, char *dst_iprange_portrange);
int filter_del(char *macaddr, char* ip_proto, char *src_iprange_portrange, char *dst_iprange_portrange);
int filter_clear();
int java_setup(char *ip_proto, char *ip_addr, int port);
int commit(int obj_type);
int rollback(int obj_type);
int export_pcap(char *ip_proto, char *ipaddr, int port);
int print_system();
int print_memory();
int print_ct(char *l7_proto);
int print_topology();
int print_thread();
int print_module(char *p_name);
int print_server();
int print_filter();
int print_java();
int print_l7();
void print_help();
void server_exit(void);

int module_add(char *p_path,char *l4_proto, int l7_proto, char *p_l7_proto_name,int mem_size);
int module_del(int l7_proto);
int module_clear(void);

#endif
